package com.start.common.entity;

import com.alibaba.fastjson2.JSONObject;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.util.List;

@Data
@Schema(name = "StartDicData", description = "字典数据")
public class StartDicData {
    /**
     * 字典名称 或者分组名称
     */
    private String label;
    /**
     * 字典值
     */
    private Object value;
    /**
     * 描述信息
     */
    private String desc;
    /**
     * 分组
     */
    private List<StartDicData> groups;

    private int order = 999;

    private boolean disabled;
    JSONObject extProp;

    public StartDicData() {
    }

    public StartDicData(String label, Object value, JSONObject extProp) {
        this.label = label;
        this.value = value;
        this.extProp = extProp;
    }

    public StartDicData(String label, Object value) {
        this.label = label;
        this.value = value;
    }

    public StartDicData(String label, Object value, boolean disabled) {
        this.label = label;
        this.value = value;
        this.disabled = disabled;
    }
}
